package net.huashitong.supervision.task.dao;

import com.sirdc.modules.core.dao.GenericQuery;
import com.sirdc.modules.core.dao.StringDao;
import net.huashitong.supervision.task.entity.SMSEntity;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * Created with IntelliJ IDEA.
 * User: ling
 * Date: 2019/10/30
 * Time: 11:34
 * To change this template use File | Settings | File Templates.
 * Description:
 */
@Repository
public class SMSDao extends StringDao<SMSEntity> {
    public List<SMSEntity> getByState(String s) {
        GenericQuery query = createQuery("obj");
        query.append(" and state = :state").setParam("state",s );
        return query.listResult();
    }
}
